<!-- 修改数据页面 -->
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<script type="text/javascript">
$(function() {
	progressClose();
	
    $('#editForm').form({
        url : '${pageContext.request.contextPath}/task/taskJob/edit',
        onSubmit : function() {
            progressLoad();
            var isValid = $(this).form('validate');
            if (!isValid) {
                progressClose();
            }
            return isValid;
        },
        success : function(result) {
            progressClose();
            result = $.parseJSON(result);
            if (result.success) {
            	parent.$.messager.alert('提示', result.msg, 'info');
                parent.$.modalDialog.openner_dataGrid.datagrid('reload');//之所以能在这里调用到parent.$.modalDialog.openner_dataGrid这个对象，是因为list.jsp页面预定义好了
                parent.$.modalDialog.handler.dialog('close');
            } else {
                parent.$.messager.alert('错误', result.msg, 'error');
            }
        }
    });
    
    $("#jobStatus").val('${entity.jobStatus}');
    $("#isConcurrent").val('${entity.isConcurrent}');
    
});
</script>
<div class="easyui-layout" data-options="fit:true,border:false" >
    <div data-options="region:'center',border:false" title="" style="overflow: hidden;padding: 3px;" >
        <form id="editForm" method="post" >
        	<input name="id" type="hidden"  value="${entity.id}">
            <table class="grid">
				<tr>
		            <td>任务名称</td>
		            <td><input name="jobName" type="text" placeholder="请输入任务名称" 
		            	class="easyui-validatebox" data-options="required:true" 
		            	value="${entity.jobName}"></td>
		        </tr>
	             
				<tr>
		            <td>任务分组</td>
		            <td><input name="jobGroup" type="text" placeholder="请输入任务分组" 
		            	class="easyui-validatebox" data-options="required:true" 
		            	value="${entity.jobGroup}"></td>
		        </tr>
	             
				<tr>
		            <td>任务启动状态</td>
		            <td>
		            	<select id="jobStatus" name="jobStatus" class="easyui-combobox" 
				        	data-options="width:140,height:29,editable:false,panelHeight:'auto'">
				            <option value="0">不启动</option>
				            <option value="1">启动</option>
				        </select>
		            </td>
		        </tr>
	             
				<tr>
		            <td>cron表达式</td>
		            <td><input name="cron" type="text" placeholder="请输入cron表达式" 
		            	class="easyui-validatebox" data-options="required:true" 
		            	value="${entity.cron}"></td>
		        </tr>
				<tr>
		            <td>springBeanID</td>
		            <td><input name="beanId" type="text" placeholder="请输入spring bean ID" 
		            	class="easyui-validatebox" data-options="required:true" 
		            	value="${entity.beanId}"></td>
		        </tr>
	             
				<tr>
		            <td>任务类</td>
		            <td><input name="beanClass" type="text" placeholder="请输入任务执行时调用哪个类的方法 包名+类名" 
		            	class="easyui-validatebox" data-options="required:true" 
		            	value="${entity.beanClass}"></td>
		        </tr>
	             
				<tr>
		            <td>任务调用的方法名</td>
		            <td><input name="methodName" type="text" placeholder="请输入任务调用的方法名" 
		            	class="easyui-validatebox" data-options="required:true" 
		            	value="${entity.methodName}"></td>
		        </tr>
	             
				<tr>
		            <td>任务并发状态</td>
		            <td>
		            	<select id="isConcurrent" name="isConcurrent" class="easyui-combobox" 
				        	data-options="width:140,height:29,editable:false,panelHeight:'auto'">
				            <option value="0">并发任务</option>
				            <option value="1">非并发任务</option>
				        </select>
		            </td>
		        </tr>
	            <tr>
		            <td>描述</td>
		            <td>
		            	<textarea name="description" rows="" cols="" >${entity.description}</textarea>
		            </td>
		        </tr>	
            </table>
        </form>
    </div>
</div>